<template>
  <div class="hide_container">
    <CommonBack :title="title"></CommonBack>
    <div class="content_box">
      <div class="img">
        <img src="../../../static/uni.png" alt="" srcset="" />
      </div>
      <div class="btn">
        <van-button type="danger" @click="goToLogin">一键登录</van-button>
      </div>
      <div class="span">
        <span>登录后享受更多权益</span>
      </div>
    </div>
  </div>
</template>

<script>
import CommonBack from "@/components/CommonBack.vue";
import { Toast } from "vant";
export default {
  name: "Hide",
  data() {
    return {
      title: "",
    };
  },
  components: {
    CommonBack,
  },
  methods: {
    firstCreate() {
      this.$store.commit("changeTabShow");
    },
    goToLogin() {
      Toast.loading();
      setTimeout(() => {
        this.$router.push({
          path: "/login",
        });
        Toast.clear()
      }, 500);
    },
  },
  created() {
    this.firstCreate();
  },
  destroyed() {
    this.$store.commit("changeTabShow");
  },
};
</script>

<style lang="less" scoped>
.hide_container {
  padding-top: 46px;
  margin-top: 3.2227rem;
  .content_box {
    .img {
      img {
        display: inline-block;
        width: 4.6875rem;
        height: 4.6875rem;
        background-color: cyan;
        border-radius: 45px;
      }
    }
    .btn {
      margin-top: 20px;
      margin-bottom: 10px;
      /deep/ .van-button {
        height: 40px;
        width: 90vw;
        border-radius: 25px;
        span {
          font-size: 14px;
        }
      }
    }

    .span {
      font-size: 12px;
      color: #afafaf;
    }
  }
}
</style>